Recently, increases in the speed and complexity of integrated circuits have worsened the problems of operation failure, a decrease in operating band, and the like due to noise in chips, variations in chip noise, clock timing fluctuations (jitter), and the like. Conventionally, signals are extracted outside an integrated circuit, and the behaviors of the signals are observed. Although the operating frequencies of integrated circuits have increased year by year, the operating frequencies of boards and packages outside the integrated circuits have not followed the increasing speeds. For this reason, it is impossible to neglect the influence of noise on a channel which is extracted outside the integrated circuit, and hence it is difficult to observe high-speed operation in the integrated circuit on the outside of the integrated circuit. This increases the need of a technique of observing internal operation by providing a measuring circuit in a chip.
A measuring circuit of this type is disclosed in Japanese Patent Laid-Open No. 2000-111587. As shown in FIG. 15, a conventional measuring circuit uses a method of using a signal value m×Td (m is an integer, and Td is a resolution) as a reference signal 1406, and comparing the reference signal 1406 with a to-be-measured signal 1407 to set, as an output signal 1401, m by which the magnitude relation between the signals is reversed. In this case, the minimum and maximum values of m are determined in accordance with the arrangements of a circuit which generates a signal value m×Td and a measuring circuit.
As shown in FIG. 16, when the value of a to-be-measured signal 1402 is m×Td+Δa, m is output as the output signal 1401. When the value of a to-be-measured signal 1403 is (m+1)×Td+Δb, m+1 is output. When the value of a to-be-measured signal 1404 is m×Td+Δc, m is output. As described above, since it is impossible to perform comparison in an interval equal to or less than Td, errors (quantization errors) corresponding to Td at maximum occur between the to-be-measured signals 1402 to 1404 and the output signals 1401 as measurement results.